#tb文件
tb_file=tb.sv
#编译输出文件
tb_obj=tb
#verilog语法版本
v_ver=-g2005-sv
#RTL文件所在相对路径
v_path=..
#-------------------------------------------------------------------------------------------------------
run_all: cmp sim gtk

cmp: 
	iverilog $(v_ver) -o $(tb_obj) -y $(v_path) $(tb_file)
#-------------------------------------------------------------------------------------------------------
sim: 
	vvp -n $(tb_obj) -lxt2
#-------------------------------------------------------------------------------------------------------
gtk: 
	gtkwave $(tb_obj).lxt
#-------------------------------------------------------------------------------------------------------
#-------------------------------------------------------------------------------------------------------
.PHONY : clean
clean  :
	 rm  -rf  $(tb_obj) *.lxt
#-------------------------------------------------------------------------------------------------------